<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ include file="../common.jsp" %>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
	<script type="text/javascript">
		$(function(){
			$("#dg").datagrid({
						rownumbers:true,
						fitColumns:true,
						singleSelect:true,
						striped:true,
						pagination:true,
						nowrap : true,  
					    collapsible : true,
						url:"usManager!query",
						nowrap:false,
						striped:true,
						collapsible:true,
						loadMsg:'数据装载中...',
						removeSort:false,
  						fronzenColumns:[[{field:'ck',checkbox:true}]],
  						remoteSort : false,  
				       frozenColumns : [ [ {  
				           field : 'ck',  
				           checkbox : true  
				       } ] ],  
					       columns : [ [ {  
					           title : '账户',  
					           field : 'usNo',  
					           width : '100',  
					           rowspan : 2,  
					           align : 'center'  
					       }, {  
					           title : '姓名',  
					           field : 'usName',  
					           width : '100',  
					           rowspan : 2,  
					           align : 'center'  
					       }, {  
					           title : '年龄',  
					           field : 'usAge',  
					           width : '100',  
					           rowspan : 2,  
					           align : 'center'  
					       }, {  
					           title : '性别',  
					           field : 'usSex',  
					           width : '100',  
					           rowspan : 3,  
					           align : 'center'  
					       }]],
						 toolbar : [ {  
							           text : '全部',  
							           iconCls : 'icon-ok' 
							       }, '-', {  
							           text : '添加',  
							           iconCls : 'icon-add'  
							       }, '-', {  
							           text : '修改',  
							           iconCls : 'icon-edit' 
							       }, '-', {  
							           text : '删除',  
							           iconCls : 'icon-remove', 
							       }, '-', {  
							           text : '查询',  
							           iconCls : 'icon-search'
							       } ]  
				});
				 displayMsg();
		});
		
		function displayMsg() 
		{  
			    $('#dg').datagrid('getPager').pagination({  
			      	 displayMsg : '当前显示从{from}到{to}共{total}记录'  
			    });  
		}  
		
	</script>
  </head>
  
  <body >
   	<table id="dg" title="用户信息">

	</table>
	
	<div id="dlg" class="easyui-dialog" style="width:400px;height:280px;padding:10px 20px"
		closed="true" buttons="#dlg-buttons">
	<div class="ftitle"></div>
	<form id="fm" method="post">
		<div class="fitem">
			<label>账户:</label>
			<input name="usNo" class="easyui-validatebox"  data-options="missingMessage:'请输入账户',required:true">
		</div>
		<div class="fitem">
			<label>姓名:</label>
			<input name="usName" class="easyui-validatebox" data-options="missingMessage:'请输入姓名',required:true,validType:'CHS'">
		</div>
		<div class="fitem" >
			<label>年龄:</label>
			<input name="usAge" class="easyui-validatebox" data-options="missingMessage:'请输入年龄',invalidMessage:'输入有误',required:true,validType:'length'">
		</div>
		<div class="fitem">
			<label>性别:</label>
			<input name="usSex" class="easyui-validatebox" validType="email" invalidMessage="请输入正确的邮箱地址">
		</div>
	</form>
</div>
<div id="dlg-buttons">
	<a href="#" class="easyui-linkbutton" iconCls="icon-ok" onclick="saveUser()">Save</a>
	<a href="javascript:$('#dlg').dialog('close')" class="easyui-linkbutton" iconCls="icon-cancel">Cancel</a>
</div>

	
  </body>
</html>
